Field of the Invention
The present invention relates to a numerical controller capable of suppressing variation in velocity due to an abrupt change in positional deviation.
Description of the Related Art
A numerical controller that causes a servo motor to drive a control axis, such as a movable portion of a machine or any other apparatus, and controls the position of the control axis, typically performs position loop control. In the position loop control, the servo motor abruptly decelerates or accelerates due to an influence of a positional deviation counter used in positional control so that smooth operation is prevented in some cases. As one solution to the problem, for example, Japanese Patent Application Laid-Open No. 2007-172394 discloses a technology that allows smooth movement of the control axis by adding an amount of positional deviation corresponding to an actual velocity acquired when a state in which no current is allowed to flow through the servo motor (serve-off state) is switched to a state in which current is allowed to flow therethrough (serve-on state) to an commanded movement amount issued to the servo motor in a first movement-command output cycle after the switching operation.
In the technology described above, however, the commanded movement amount issued to the servo motor is so outputted that the actual velocity at which the control axis moves when the servo-off state is switched to the servo-on state is set to be an initial velocity. The following problem therefore remains unsolved: When some type of load, such as external force, acts on the servo motor being driven in the servo-on state under the position loop control, and the load is abruptly removed after positional deviation is accumulated, the servo motor abruptly accelerates with its maximum torque in an attempt to eliminate the accumulated positional deviation, resulting in an unstable velocity.
For example, when the velocity of a drive axis based on a commanded movement amount Pcmd in each distributed cycle is controlled to be a constant velocity Vcmd, positional deviation Err accumulated in a positional deviation counter is typically constant, as shown in FIG. 7. However, when an actual velocity V0 of the drive axis decreases due to an applied load, the discrepancy <1>, <2>, and <3> between the commanded movement amount and the actual movement amount of the drive axis increases, resulting in an increase in positional deviation Err. When the load is then abruptly removed, the actual velocity V0 of the drive axis abruptly changes in the following distributed cycle [A] because the positional deviation Err is instantly eliminated, undesirably resulting in unstable action of the drive axis.